package com.aliyun.messagemgt.service.impl;

import org.junit.runner.RunWith;
import org.mockito.junit.MockitoJUnitRunner;

/**
 * @author niulei
 * @date 2020/12/2
 */
@RunWith(MockitoJUnitRunner.class)
public class SensitiveLogServiceImplTest {

   /* @InjectMocks
    @Autowired
    private SensitiveLogServiceImpl sensitiveLogService;

    @InjectMocks
    @Autowired
    private SmsSignServiceImpl smsSignService;

    @Mock
    private SensitiveLogMapper sensitiveLogMapper;

    @Mock
    private SmsSignMapper smsSignMapper;

    @Test
    @Rollback
    public void addSensitiveLogTest() {
        SensitiveLog sensitiveLog = new SensitiveLog();
        SceneTemplateQuery sceneTemplateQuery = new SceneTemplateQuery();
        Mockito.when(sensitiveLogMapper.addSensitiveLog(Mockito.any())).thenReturn(1);
        sensitiveLogService.addSensitiveLog(sensitiveLog);
    }

    @Test
    @Rollback
    public void listSensitiveLogTest() {
        SensitiveLogQuery sensitiveLogQuery = new SensitiveLogQuery();
        Page<SensitiveLogExportModel> sensitiveLogExportModels = new Page<>();
        Mockito.when(sensitiveLogMapper.listSensitiveLog(Mockito.any())).thenReturn(sensitiveLogExportModels);
        sensitiveLogService.listSensitiveLog(sensitiveLogQuery);
    }

    @Test
    @Rollback
    public void countSensitiveLogTest() {
        SensitiveLogQuery sensitiveLogQuery = new SensitiveLogQuery();
        Mockito.when(sensitiveLogMapper.countSensitiveLog(Mockito.any())).thenReturn(1);
        sensitiveLogService.countSensitiveLog(sensitiveLogQuery);
    }

    @Test
    @Rollback
    public void getSmsSignsTest() {
        ArrayList<SmsSignVO> smsSignVOArrayList = new ArrayList<SmsSignVO>();
        Mockito.when(smsSignMapper.getSmsSigns(Mockito.anyInt())).thenReturn(smsSignVOArrayList);
        smsSignService.getSmsSigns(1);
    }*/
}
